package com.cloudcc.mobile.dao.impl;

import java.net.URLEncoder;
import java.util.List;

import com.cloudcc.cloudframe.net.async.EventRequest;
import com.cloudcc.mobile.AppContext;
import com.cloudcc.mobile.dao.UserDao;
import com.cloudcc.mobile.entity.CallLogMatchEntity;
import com.cloudcc.mobile.event.BeauEventList;
import com.cloudcc.mobile.util.NetWork;
import com.cloudcc.mobile.util.Tools;
import com.cloudcc.mobile.util.UrlTools;
import com.loopj.android.http.RequestParams;

public class UserDaoImpl implements UserDao {

	/**
	 * 查询分页企业通讯录
	 */
	@Override
	public String getUsers(String expressions) {
		try {
			// expressions="name%20like'%25"+name+"%25'"+b;
			String px = "isusing = '1'";
			String a = URLEncoder.encode(px, "utf-8");
			String url = UrlTools.url + UrlTools.url_path
					+ "serviceName=cquery&objectApiName=ccuser&expressions="
					+ a + expressions + "&binding=" + AppContext.binding;
			String jsonString = NetWork.get(url.trim());
			return jsonString;
		} catch (Exception e) {
			Tools.handle(e);
		}
		return null;
	}

}
